<script lang="ts" setup>
import { getSvg } from "@/utils/index";
const { dayjs, userTimeZone } = useDayJs();
const svgFileName = ref("Component_4");
onMounted(() => {
  // 计算当前日期相对于基准日期的偏移量
  const today = dayjs().tz(userTimeZone).startOf("day");
  const baseDate = dayjs("2025-01-01").startOf("day"); // 基准日期，可以根据需要调整
  const offset = today.diff(baseDate, "day") % 3; // 3天循环
  // 根据偏移量选择图片文件名
  if (offset === 0) {
    svgFileName.value = "Component_4";
  } else if (offset === 1) {
    svgFileName.value = "Component_4(1)";
  } else if (offset === 2) {
    svgFileName.value = "Component_4(2)";
  }
});
</script>
<template>
  <div class="center relative mb-14">
    <img class="mw-01" :src="getSvg(svgFileName)" alt="" />
    <div
      class="text-12 text-[#fff] font-weight-400 absolute left-[50%] top-25 translate-x-[-50%] break-normal"
    >
      In this blessed month,let your heart be filled with gratitude,your soul
      with patience,and your actions with kindness.
    </div>
  </div>
</template>
